mynote todo plan
方东
mynote todo 马辉
mynote todo lg
hurentao todo
2.2
阅读统计
更新数据:
update user set nick = id where nick is null or nick = ''
这里没法使用 ifnull:
$query->select('u.id, u.email, u.mobile, u.nick, u.pic, u.reg_time,

编辑
./docs 检查
公用 db & es 操作部分
uid & path 换 aid
ON DUPLICATE KEY UPDATE;insert-update
after: 如果已经是了,就不要再更新了
手动触发更新
article.username 作废 - 还不行,repo update by username 需要,gogs传的是username
不能连续 rename,需要刷新
发布、修改时间
lv1= lv2= type=
外部更新:修改时间由git 时间决定;内部由发布时间定
图片
lv1= lv2= type=
图片存储,改为 md5 两级 dir
lv1= lv2= type=
图片转储可选,默认不开启?
book 个人主页
文章访问历史记录
ip反解区域
lv1= lv2= type=
docs 下仓库,origin 配置出错,导致访问很慢。提示不明确(没有)
lv1= lv2= type=
重复点赞:数据保存重复,改为取消?
无轮播图:文章信息不存在
lv1= lv2= type=
es search
searchByType 需要拆分,不同类型返回的结果格式都不一样
es 链接不通的处理,不能卡死
没有一篇文章时,重新索引报错:
2019-11-13 11:27:48 [127.0.0.1][-][-][error][Elasticsearch\Common\Exceptions\BadRequest400Exception] Elasticsearch\Common\Exceptions\BadRequest400Exception: {"error":{"root_cause":[{"type":"parse_exception","reason":"request body is required"}],"type":"parse_exception","reason":"request body is required"},"status":400} in /home/www/mynote/vendor/elasticsearch/elasticsearch/src/Elasticsearch/Connections/Connection.php:615
显示总数量
tag 支持: sync 时需要同步的更新,不能丢失
repo update
lv1= lv2= type=
文章编码非 utf-8 处理:
/api/article/show
2020-08-08 16:06:15 [127.0.0.1][-][-][error][yii\base\InvalidArgumentException] yii\base\InvalidArgumentException: Malformed UTF-8 characters, possibly incorrectly encoded. in /home/www/mynote/basic/vendor/yiisoft/yii2/helpers/BaseJson.php:137
Stack trace:
#0 /home/www/mynote/basic/vendor/yiisoft/yii2/helpers/BaseJson.php(68): yii\helpers\BaseJson::handleJsonError(5)
#1 /home/www/mynote/basic/vendor/yiisoft/yii2/web/JsonResponseFormatter.php(121): yii\helpers\BaseJson::encode(Array, 320)
#2 /home/www/mynote/basic/vendor/yiisoft/yii2/web/JsonResponseFormatter.php(105): yii\web\JsonResponseFormatter->formatJson(Object(yii\web\Response))
#3 /home/www/mynote/basic/vendor/yiisoft/yii2/web/Response.php(1073): yii\web\JsonResponseFormatter->format(Object(yii\web\Response))
#4 /home/www/mynote/basic/vendor/yiisoft/yii2/web/Response.php(343): yii\web\Response->prepare()
#5 /home/www/mynote/basic/vendor/yiisoft/yii2/base/Application.php(400): yii\web\Response->send()
#6 /home/www/mynote/basic/web/index.php(39): yii\base\Application->run()
用户 rlp setting
不用传自己的手机号?或者提示更明显些
新注册用户没有钩子 webhooks
- 用户已登录状态再进行二次登录未弹出提示框(可快捷跳转至其他页面)

简单实现:checkLogin
checkNotLogin 需要配合 ssr,见 settting.vue
昵称注册必填
注册、重置密码 成功后跳转至 首页
GET_USERINFO 合并到 RECORD_USERINFO
前端 ukey -> uid
手机只能换绑,不能解绑
userinfo
auth.getUserInfo 登录用户信息
api.getAnyUserInfo 任意用户信息 -- 隐藏手机号等信息
登录成功、auth.getUserInfo 记录用户信息到 state。
需要一个方法重新获取信息。目前仅刷新时重新获取(初始化)userInfoInited
切面 后端
lv1= lv2= type=
normalize path unittest
验证整型数组
lv1= lv2= type=
\app\lib\SessionTools::init 多次初始化,还带数据库查询
lv1= lv2= type=
baseController::init 初始化优化
lv1= lv2= type=
log
ct_log 按日期分隔;或用clog
去掉clog,和slog容易混淆
安全
除了index.php,其他php都禁止访问
切面 前端
replyBtnItem.addEventListener
这种不需要移除?
keep-alive
lv1= lv2= type=
$route 变化触发 search
followUserWrapper?
960 统一
@media (max-width 960px) {
跳转逻辑统一:用 <nuxt-link>代替;哪部分跳转哪里明确;hover 状态;是否要文字高亮?
整块可点击
<li v-for="article in articles" :class="[article.thum != '' ? 'have-img' : '']" @click="handleRoute({username: article.username, detail: article.aid})" style="cursor: pointer;">
/**
* 查看文章内容
*
* @param id
*/
handleFileClick(id) {
改用 link

lv1= lv2= type=
接口访问
$axios 不在 pages 中使用
api 都不进行参数验证,因为与应用是强耦合的
request 封装; API Result 优化
不要所有的网络请求都显示进度,太干扰用户??
特别是转储
lv1= lv2= type=
dialog
点击外侧关闭,容易误触
lock-scroll 为 true 导致 scroll to top
loading 动画

<div class="comment-loading" v-loading="true" style="height: 100px"></div>
bug fix --------------
lv1= lv2= type=
编辑
rename 需要先创建 path
rename 相对路径拼接
rename: 传入 old name,作为验证
检查删除文件 exist
文章数 add 没有统计
deal_with_html ??
path 带 ' ?
getTags 随编辑时文章内容一同获取(/api/article/show)
首页
tool
blame 快捷
edit 编辑
done
make result
$session = SessionTools::getSession(); 提取
login check 登录检查 - 改为统一处理
docs 下仓库,origin 配置出错,导致访问很慢。提示不明确(没有)
baseController::init 初始化优化
other
lv1= lv2= type=
http_post header fix
_create_collaborators
* uTODO: use php curl instead!
PHP用CURL发送Content-type为application/json的POST请求方法
验证码时间统一
重置密码 要验证手机号、邮箱是否属于当前用户
FORMAT_JSON 可以在 requestHandler中统一处理?
退出浏览器就会退出登录 修改 php session timeout
php session 时间 timeout
无图片

fastadmin 后台 标签管理等
artpv 没有去重
编辑页,草稿列表
掘金每个草稿都有唯一id:https://juejin.cn/editor/drafts/6965128124325756959
关闭后还可以通过 history 打开
指示箭头

搜索 查看更多优化
yr todo ---
几种图标
测试文档整理 https://t4.uninote.com.cn/book/1002/357
mynote testing 测试说明
已关闭 bug 整理到用例/测试说明
check:http://zentao.uninote.com.cn/zentao/bug-view-44.html#8
74 文章访问历史记录 UA
http://zentao.uninote.com.cn/zentao/task-view-74.html
王淑丽 todo ---
lv1= lv2= type=
1 banner 按钮的颜色、透明度调整
http://zentao.uninote.com.cn/zentao/task-view-1.html
lv1= lv2= type=
65 回车支持(form表单规范)
http://zentao.uninote.com.cn/zentao/task-view-65.html
65 回车支持
http://zentao.uninote.com.cn/zentao/task-view-65.html
f65 回车
http://video.dajxyl.com/video_play.html?video_url=https://admin.dajxyl.com/oss?path=video/upload/202106/20210623_220933.mp4Ġ
f65 review
http://video.dajxyl.com/video_play.html?video_url=https://admin.dajxyl.com/oss?path=video/upload/202106/20210624_140620.mp4
那就跳到最后一个了,就不要再跳了
你把你所有做,压缩成一个commit,基于master新建一个feat-65-3分支,提交到上面
重新整理代码,
http://video.dajxyl.com/video_play.html?video_url=https://admin.dajxyl.com/oss?path=video/upload/202106/20210626_152940.mp4
规范注意,格式化全部混在一起
http://video.dajxyl.com/video_play.html?video_url=https://admin.dajxyl.com/oss?path=video/upload/202106/20210626_153904.mp4
把回车+验证做好,再加200?
整理代码 + 50
eslint + 100?
第一次输错密码后,就无法再触发登录了
bug: 58 两次询问是否离开
http://zentao.uninote.com.cn/zentao/bug-view-58.html
ssr note 注意
lv1= lv2= type=
登录失效问题
php.ini 改错了
通过 phpinfo 查看配置是否生效
redis 查看 ttl
http://zentao.uninote.com.cn/zentao/bug-view-67.html
lv1= lv2= type=
73 文库列表中的文章链接到个人文库
http://zentao.uninote.com.cn/zentao/task-view-73.html
lv1= lv2= type=
47 接口优化
http://zentao.uninote.com.cn/zentao/task-view-47.html
lv1= lv2= type=
56 添加快捷编辑按钮,点击后进入编辑页面
http://zentao.uninote.com.cn/zentao/task-view-56.html
lv1= lv2= type=
64 头像上传控件替换
http://zentao.uninote.com.cn/zentao/task-view-64.html
lv1= lv2= type=
5 隐私、注册协议
http://zentao.uninote.com.cn/zentao/task-view-5.html
lv1= lv2= type=
77 滚动条优化
http://zentao.uninote.com.cn/zentao/task-view-77.html
lv1= lv2= type=
78 作者列表 seo
http://zentao.uninote.com.cn/zentao/task-view-78.html
lv1= lv2= type=
82 html 格式显示支持
http://zentao.uninote.com.cn/zentao/task-view-82.html
element.id 存在时不需要生成
todo bugs
删除提示删除的文件名,加红
删除后自动切换文章
新增要提示最终的完整链接

点击注册时,显示关闭登录框
http://video.dajxyl.com/video_play.html?video_url=https://admin.dajxyl.com/oss?path=video/upload/202106/20210628_121017.mp4
这几个链接都需要处理

[cmd]: git add *
warning: You ran 'git add' with neither '-A (--all)' or '--ignore-removal',
whose behaviour will change in Git 2.0 with respect to paths you removed.
Paths like 'a/&¥、/.md' that are
removed from your working tree are ignored with this version of Git.
* 'git add --ignore-removal <pathspec>', which is the current default,
ignores paths you removed from your working tree.
* 'git add --all <pathspec>' will let you also record the removals.
Run 'git status' to check the paths you removed from your working tree.
[cmd]: git add -u
转存 - 撤销 - 再点击转储无效(没有接口请求)
_create_webhook 可能多次创建 -- 查询并删除
SELECT count(*) as cnt, repo_id
FROM `webhook`
GROUP BY repo_id
having cnt > 1
路径统一做 trim 处理,每一级都要做 -- 与操作系统统一
session_start 输出移除
动态 思考 think
导入(掘金、csdn、公众号)
html支持
变现 广告
体验 优化 引导
推广
seo
文章
语雀
往专业化的方向靠
右键显示编辑菜单 or 默认的浏览器菜单
http://video.dajxyl.com/video_play.html?video_url=http://admin.dajxyl.com/oss?path=video/upload/202107/20210727_175257.mp4
lv1= lv2= type=
84 md to html 全部使用 markdown-it,逻辑优化;html to text 优化
http://zentao.uninote.com.cn/zentao/task-view-84.html
php commonmark 和 markdown-it 的解析结果还是不一样,因此统一
lv1= lv2= type=
85 有缓存文件则直接使用,不再使用时间戳比较
http://zentao.uninote.com.cn/zentao/task-view-85.html
http://video.dajxyl.com/video_play.html?video_url=http://admin.dajxyl.com/oss?path=video/upload/202108/20210814_205304.mp4
lv1= lv2= type=
86 heading-id 生成-解析-定位
http://zentao.uninote.com.cn/zentao/task-view-86.html
https://docs.dajxyl.com/book/1/2771
格式:
[id:id-title]
lv1= lv2= type=
88 markmap
http://zentao.uninote.com.cn/zentao/task-view-88.html
https://github.com/gera2ld/markmap
E:\projects\fe\mindmap-test
https://mp.weixin.qq.com/s/k3qITl7PfZhkinkXb_j3DA
d3 加载顺序问题
http://video.dajxyl.com/video_play.html?video_url=http://admin.dajxyl.com/oss?path=video/upload/202203/20220306_104739.mp4
baidu 统计导致不兼容
browser 直接加载方式
添加按钮
html 格式支持
快捷键 翻页
保存为图片?
npm install node 10 不支持
nvm 需要卸载 翻墙重新安装
nuxt.config.my.js 丢失问题?--不要加入git
front 更新注意要重启 pm2:
pm2 restart node
否则出现资源文件加载不到的问题
jenkins,手动构建参数配置;
front dist 推送,不稳定
ssh copy
--
lv1= lv2= type=
90 编辑器同步滚动可选
http://zentao.uninote.com.cn/zentao/task-view-90.html
--editor:
lv1= lv2= type=
91 文章权限-基础版本 article grant
http://zentao.uninote.com.cn/zentao/task-view-91.html
https://processon.com/diagraming/62c109330e3e74659207b11c

Glob-like file and pattern matching utility.
https://github.com/PHLAK/Splat
group
art_grant:
id
owner_uid
grant_uid
auth: *
type: read/write
因此,如果是使用ISAPI 的方式来运行PHP就必须用Thread Safe(线程安全)的版本;而用FastCGI模式运行PHP的话就没有必要用线程安全检查了,用None Thread Safe(NTS,非线程安全)的版本能够更好的提高效率。
可读配置:
全部可读,最常见设置,拒绝配置不起作用
部分可读(必须在白名单中,并且不被黑名单覆盖)
可写配置优于可读配置
未登录怎么算?
private function _sql_go($uid, $val, $type)
{
$sql = "UPDATE `user` SET `{$type}`= :n WHERE `id` = :m";
$int = \Yii::$app->db->createCommand($sql)->bindValue(':n',htmlspecialchars($val))->bindValue(':m',trim($uid))->execute();
$this->_update_session($uid);
return $int;
}
$sql = "UPDATE `user` SET `{$type}`= :n WHERE `id` = :m";
$int = \Yii::$app->db->createCommand($sql)->bindValue(':n',htmlspecialchars($val))->bindValue(':m',trim($uid))->execute();
{"grant":{"public":true}}
DbTools::execute("update user set settings = :settings where id=$uid", [":settings" => $settings]);
{"grant":{"public":true}, "xx": 1}
`grant_type` tinyint(4) NOT NULL DEFAULT '1' COMMENT '0: forbidden; 1: granted',
`op_type` tinyint(4) NOT NULL DEFAULT '1' COMMENT '1: read; 2: write',
return array_filter($grants, function($grant) use ($grant_type, $op_type){
if ($grant['grant_type'] == $grant_type && $grant['op_type'] == $op_type) {
return true;
}
return false;
});
{"grant":{"is_public":false}}
$check_uid
bool 参数?
is_public
数组引用传递
case:隐藏某些文章
用户设置,集中到一个字段,避免多次数据库变动
todo
缓存优化,避免每次都访问数据库,public是默认值,为绝大多数的情况。
powder 补充
write 权限实现
刷新页面时要提示没有权限,现在显示的是空白页
没有权限的列表也过滤掉?
recent todo --
$articleModel->id 改为 type 判定
没有配置要报错:
git config --global user.name uninote-editor
git config --global user.email www@uninote.com.cn
git config --global push.default simple
html 格式支持;注意xss问题
标题唯一ID,生成与引用、定位
指定文章可见:uid uid 空格分隔
搜索时不可见的文章被过滤掉;
如果某次搜索都被过滤了,自动加载下一页?
通过github 链接导入文章?用指定地址的指定分支重新初始化个人仓库;将原始master重命名为: master-$request_num
global $request_num;
$branch = "update_$request_num";
---fe:
修改密码优化:
不需要输入验证码
reset:第二次的倒计时修复
uninote 重定向到微信公众号
es composer 内联
对话框统一圆角
忘记密码 不需要登录
hover 时加下划线

删除文件夹 - 只能删除数据库中记录的,因为可能存在其他类型的文件,或者数据库与 fs 不同步
sync 不改变更新时间
图片转存 后台异步
# 获取最新的 commits 值
. env.sh
back.sh
fc.sh
front.sh
recent todo2 --
nextTick?
save-svg-as-png
https://www.npmjs.com/package/save-svg-as-png
改为这个:
config.devtool = 'eval-source-map';


跟随不要超过一半
用户目录:
时间过滤
tree common op
内联,修改源码
图片经常不能放大的问题
顶部显示全路径,点击展开全部。
link with editor

新增 anchor:显示当前目录下文档以及子文件夹
透明问题

群组支持
vscode 插件
- [heading-id] 生成
- 截图粘贴
--mynote
esc 支持
加载问题
markmap
svg 下载图片
脑图可以直接发送url
lv1= lv2= type=
--editor:
取消同步滚动
save后滚动到其他地方了
同步滚动取消后的bug:
http://video.dajxyl.com/video_play.html?video_url=http://admin.dajxyl.com/oss?path=video/upload/202206/20220627_145015.mp4
es、kibana 重新用 centos7 部署
84 md to html 全部使用 markdown-it,逻辑优化;html to text 优化
common mark 移除 from vendor
lv1= lv2= type=
92 fh html 格式支持
http://zentao.uninote.com.cn/zentao/task-view-92.html
- 基础样式支持
- tnd跳转
- 统一站内跳转
- 图片支持
- debugger
- 左侧响应式菜单(用户目录)定位
lv1=mysql lv2= type=
js viewport
tnd 链接跳转
跳转404
用 : 来判断绝对路径
- 去掉头部导航
overflow:scroll -- padding 为 scrollbar 预留位置
visited 颜色
第一个没有绿色?

this.$parent.$data
当前文章 hash 跳转
路径大小写问题
GNU bash manual--------
独立浏览器浏览支持
图片加载与大图查看
非 fh 格式不处理
链接绿色
格式美观
上下篇导航
覆盖索引 这里找不到文章 - 两次接口调用,一次报找不到
remove 时也要加 true:
window.addEventListener("click", this.handleClickBody, true);
图片放 static/pic 下
pic -> /home/www/fh_html2/doc/pic
window.__NUXT__
权限:
https://uninote.com.cn/book/1053/820
<pre><span class='s0'><a href='test.html'>他人文章test </a></span></pre>
性能优化:
- 首屏时间
- 显示left慢
- 默认折叠
- 懒加载
- 回退状态保持
fh's hash 支持
tree 常规操作
当前页跳转
展示全路径
handleClickBody 不用等到 doc loaded
不处理:
- book/xx
- 绝对路径
fh 中的 <script> 通过 xhr 的方式加载,不会被执行。
- 先进 md 页面,再进入 fh 页面
fhformat 改为某个id
hook:
- 图片
- 链接调整
实时过滤

isMaster ?
resArticleList 不需要?可以被 user_struct 代替
link with:scroll into view
tree 上按钮:
this.$el.querySelector(".file-on").scrollIntoViewIfNeeded();
mounted后将
book/1053/0/temp3.html 处理为
book/p/temp3.html
p 为 by path 的标记。
preimage bug
有大量的图片加载报错
打包时 nuxt.config.my.js 的处理
lv1= lv2= type=
自动同步
git sync back 体系 using beyondcompare bc

lv1= lv2= type=
93 支持用户目录下相对路径的图片展示
http://zentao.uninote.com.cn/zentao/task-view-93.html
方案:在 ty 编辑时,path/to/file.md 引用 img/a.png 的相对路径为:../../img/a.png, 最终处理为 img/a.png, 因为 leading dotdot 没有意义。
TODO: 这种在 online 编辑时无法预览图片。
初始化脚本:
ln -s /home/www/mynote/basic/web/docs /home/www/front/static/book
front:
在多图时,直接刷新没有问题(因为 getTitles 计算很慢),导航过来有问题。fix:使用防抖节流
节流的 maxwait 需要设置比较大,否则效果不好。
尝试 不要 leading?